﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Globalization;
using System.Threading;

namespace Ex7.StringExtension
{
    public static class Extension
    {
        public static string ToTitledCase(this String str)
        {
            CultureInfo c = Thread.CurrentThread.CurrentCulture;
            TextInfo textInfo = c.TextInfo;
            return textInfo.ToTitleCase(str);
        }
    }
    class StringExtension
    {
        static void Main(string[] args)
        {
            String str = "this is example";
            Console.WriteLine(str.ToTitledCase());
        }
    }
}
